<!DOCTYPE html>
<html xmlns:v-bind="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="utf-8">
    <title>vue01</title>
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
</head>

<body>


<div id="app">
    <!--<div v-bind:class="{mydiv:flag,mydiv2:hasborder}" class="mydiv1">{{msg}}</div>-->
    <div v-bind:class="classObj" class="mydiv1">{{msg}}</div>
</div>


</body>


<script>
    var app = new Vue({
        el: '#app',
        data: {
            msg: 'hhh',
            classObj:{
                mydiv:true,
                mydiv2:true
            },
            flag: true,
            hasborder:true
        }
    })

</script>

<style>
    .mydiv{
        font-weight: bold;
        color: #ff0000;
    }
    .mydiv1{
     font-size: 30px;
    }
    .mydiv2{
        border: 1px solid #dedede;
    }
</style>
</html>
